<?php TPL::output('admin/global/header.tpl.htm'); ?>

<!--left-->
<?php TPL::output('admin/global/left.tpl.htm'); ?>
<!--left-->

<!-- main -->
<div id="main-content">
	<div class="clear"></div>
	<div class="content-box">
		<div class="content-box-header">
			<h3><?php echo $this->crumb['last']['name']; ?></h3>
			<ul class="content-box-tabs">
			</ul>
			<div class="clear"></div>
		</div>
		
		<div style="width:950px; margin:5px;">
		
		<div class="content-box-content" style="width:400px; float:left;">
			<div class="tab-content default-tab" id="tab1">
				<?php if(!$this->job_list){ ?>
				<div class="notification attention png_bg"> <a href="javascript:;" class="close"><img src="<?php echo G_STATIC_URL;?>/admin/images/icons/cross_grey_small.png" title="Close this notification" alt="close" /></a>
					<div> 没有内容 </div>
				</div>
				<?php }else{ ?>
				<form id="_job_form" action="admin/user_manage/save_job_ajax/" method="post">
					<table class="list">
						<thead>
							<tr>
								<!--th><input class="check-all" type="checkbox" /></th-->
								<th>ID</th>
								<th>职位名称</th>
								<th></th>
							</tr>
						</thead>
						<tbody style="border-bottom: 1px solid #ddd; height:20px;">
							<?php foreach ($this->job_list AS $key => $val) { ?>
							<tr>
								<th><?php echo $key; ?></td>
								</div>
								<td><input class="text-input normal-input" style="width:90%;" name="job_list[<?php echo $key; ?>]" value="<?php echo $val; ?>" /></td>
								<td><a href="javascript:;" onClick="if(confirm('确定删除？')){ajax_request(G_BASE_URL + '/admin/user_manage/remove_job/job_id-<?php echo $key; ?>');}" title="删除">删除</a></td>
							</tr>
							<?php } ?>
						</tbody>
					</table>
					
					<p>
						<input class="button" type="button" onClick="ajax_post($('#_job_form'), _form_process);" value=" 保  存 " />
					</p>
				</form>
				<?php } ?>
			</div>
			</div>
			
			<div class="content-box-content" style="width:300px; float:left;">
		<div class="tab-content default-tab" id="tab1">
			
			<form id="_save_form" action="admin/user_manage/add_job_ajax/" method="post">
				<fieldset>
				<p style="width:250px;">
					<label>添加新职位：<span style="font-weight:normal;">(一行一个职位名称)</span></label>
					<textarea name="jobs" cols="30" rows="10" id="jobs"></textarea>
				</p>
				<p>
					<input class="button" type="button" onClick="ajax_post($('#_save_form'), _form_process);" value="保存" />
				</p>
				</fieldset>
				<div class="clear"></div>
			</form>
			
		</div>
	</div>
			
			
			
		
		</div>
		
		<div class="clear"></div>
		<div id="notf_tip" style="display:none;" class="notification png_bg"> <a href="javascript:;" class="close"><img src="<?php echo G_STATIC_URL;?>/admin/images/icons/cross_grey_small.png" alt="关闭" /></a>
			<div id="notf_cont"></div>
		</div>
	</div>

<!-- footer -->
<?php TPL::output('admin/global/footer.tpl.htm'); ?>
<!-- footer -->

</div>
<!-- main -->

</div>

</body>
</html>